using System;

/// <summary>
/// Db logic for the game object ItemType
/// </summary>
public class GameItemTypeDbLogic : IDTODbLogic<GameItemType>
{
	#region IDTODbLogic[ItemType] implementation
	public GameItemType CreateShallowObjectFromDataRow (System.Data.DataRow row)
	{
		GameItemType newItemType = new GameItemType();
		newItemType.GameItemTypeCd = row["game_item_type_cd"].ToString();
		newItemType.ItemTypeDescription = row["game_item_description"].ToString();
		newItemType.CanHeal = bool.Parse(row["can_heal"].ToString());
		newItemType.BodyPartWornCd = row["body_part_worn_cd"].ToString();
		return newItemType;
	}

	public void PopulateChildObjects (GameItemType objectToMap, GameDatabase gameDatabase)
	{
		return;
	}

	public string SelectStatement {
		get {
			return "select game_item_type_cd, game_item_description, can_heal, body_part_worn_cd from game_item_type";
		}
	}
	#endregion
}
